//
//  RYCActionSheet.m
//  EWallet
//
//  Created by hemingway payegis on 13-5-29.
//  Copyright (c) 2013年 payegis. All rights reserved.
//

#import "RYCActionSheet.h"

@implementation RYCActionSheet

- (void)dealloc
{
    self.completionBlock = nil;
    [super dealloc];
}

- (void)setCompletionBlock:(RYCActionSheetCompletionBlock)completionBlock
{
    self.delegate = self;
    [_completionBlock release];
    _completionBlock = [completionBlock copy];
}

- (void)actionSheet:(UIActionSheet *)actionSheet clickedButtonAtIndex:(NSInteger)buttonIndex
{
    if (_completionBlock)
    {
        _completionBlock(buttonIndex);
    }
}
@end
